Skip to content

feat(tui): add session model picker#49

Open
qkunio wants to merge 1 commit into
MagicCube:mainfrom
qkunio:feature/model-select-command
Open

feat(tui): add session model picker#49
qkunio wants to merge 1 commit into
MagicCube:mainfrom
qkunio:feature/model-select-command

Conversation

@qkunio
Copy link
Copy Markdown

@qkunio qkunio commented May 29, 2026

1. What does this PR do?

This PR adds a /model command to the TUI so users can switch the active model for the current session.

Typing /model opens an in-terminal picker where users can move with the arrow keys and press Enter to switch models. Typing /model <name> still switches directly by configured model name.

The selected model is only applied to the current TUI session. It does not update config.yaml, and it does not clear the existing conversation history.

2. Why?

Helixent already supports multiple configured models, but changing models during interactive use requires leaving the current TUI flow and changing the default model externally.

For coding sessions, it is useful to move between models without losing context. A session-scoped picker keeps the behavior lightweight and avoids surprising persistence changes.

截屏2026-05-29 16 48 25

3. How is this tested?

Ran:

bun run check

Result:

228 pass
0 fail

4. Checklist

  • /model opens a TUI model picker.
  • /model <name> switches directly by configured model name.
  • Model switching affects only the current session.
  • Existing conversation history is preserved after switching.
  • Startup model creation and runtime switching share the same model factory.
  • Code passes bun run check.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant